package com.iplant.mes.service.po.sfc;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.iplant.base.po.BasePO;
import com.iplant.base.po.enums.DBSchemas;
import com.iplant.base.utils.annotation.po.DBBasePO;
import com.iplant.base.utils.annotation.condition.DBCondition;
import com.iplant.base.utils.annotation.field.DBField;
import com.iplant.base.utils.annotation.join.DBJoin;

/**
 * 开工检查
 *
 * @author YouWang·Peng
 * 2023-9-20 09:20:46
 */
@DBBasePO(TableName = "sfc_task_start_check", Name = false, Active = false, Schemas = DBSchemas.MES,
        CheckName = {"Code", "TaskSelfID"}, CodeAuto = true, CodePrefix = "STSC-{yyyyMMdd}-")
public class SFCTaskStartCheck extends BasePO {
    /**
     * 派工任务
     */
    @DBCondition
    @DBField
    public int TaskSelfID = 0;

    @DBJoin(name = "Code", tableName = "sfc_task_self", tableAsName = "sfc_task_self1", Schemas = DBSchemas.MES,
            MainTableField = "TaskSelfID")
    public String TaskSelfCode = "";

    /**
     * 工位ID
     */
    @DBJoin(name = "StationID", tableName = "sfc_task_self", tableAsName = "sfc_task_self1", Schemas = DBSchemas.MES,
            MainTableField = "TaskSelfID")
    public int StationID = 0;

    @DBJoin(name = "Name", tableName = "fmc_station", tableAsName = "fmc_station1", Schemas = DBSchemas.Basic,
            JoinIndex = 2,
            ConditionalJoin = "sfc_task_self1.StationID=fmc_station1.ID")
    public String StationName = "";

    @DBJoin(name = "Code", tableName = "fmc_station", tableAsName = "fmc_station1", Schemas = DBSchemas.Basic,
            JoinIndex = 2,
            ConditionalJoin = "sfc_task_self1.StationID=fmc_station1.ID")
    public String StationCode = "";

    /**
     * 报警状态
     */
    @DBJoin(name = "Status", tableName = "fmc_station", tableAsName = "fmc_station1", Schemas = DBSchemas.Basic,
            JoinIndex = 2,
            ConditionalJoin = "sfc_task_self1.StationID=fmc_station1.ID")
    public int StationStatus = 0;
    /**
     * 是否检查点检
     */
    @DBJoin(name = "IsSpotCheck", tableName = "fmc_station", tableAsName = "fmc_station1", Schemas = DBSchemas.Basic,
            JoinIndex = 2,
            ConditionalJoin = "sfc_task_self1.StationID=fmc_station1.ID")
    public int IsSpotCheck = 0;

    /**
     * 物料是否齐套
     */
    @DBField
    public int MaterialIsOk = 0;
    /**
     * 人员资质是否ok
     */
    @DBField
    public int QualificationIsOk = 0;
    /**
     * 设备状态是否ok
     */
    @DBField
    public int DeviceIsOk = 0;

    /**
     * 工艺参数是否ok
     */
    @DBField
    public int ProcessParametersIsOk = 0;
    /**
     * 环境参数是否ok
     */
    @DBField
    public int EnvironmentalParametersIsOk = 0;
    /**
     * 质量参数是否ok
     */
    @DBField
    public int QualityParametersIsOk = 0;

    /**
     * 物料是否填写完毕
     */
    public int MaterialIsWrite = 0;
    /**
     * 工艺参数是否填写完毕
     */
    public int ProcessParametersIsWrite = 0;
    /**
     * 环境参数是否填写完毕
     */
    public int EnvironmentalParametersIsWrite = 0;


    @JsonProperty("TaskSelfID")
    public int getTaskSelfID() {
        return TaskSelfID;
    }

    public void setTaskSelfID(int taskSelfID) {
        TaskSelfID = taskSelfID;
    }

    @JsonProperty("TaskSelfCode")
    public String getTaskSelfCode() {
        return TaskSelfCode;
    }

    public void setTaskSelfCode(String taskSelfCode) {
        TaskSelfCode = taskSelfCode;
    }

    @JsonProperty("MaterialIsOk")
    public int getMaterialIsOk() {
        return MaterialIsOk;
    }

    public void setMaterialIsOk(int materialIsOk) {
        MaterialIsOk = materialIsOk;
    }

    @JsonProperty("QualificationIsOk")
    public int getQualificationIsOk() {
        return QualificationIsOk;
    }

    public void setQualificationIsOk(int qualificationIsOk) {
        QualificationIsOk = qualificationIsOk;
    }

    @JsonProperty("DeviceIsOk")
    public int getDeviceIsOk() {
        return DeviceIsOk;
    }

    public void setDeviceIsOk(int deviceIsOk) {
        DeviceIsOk = deviceIsOk;
    }

    @JsonProperty("ProcessParametersIsOk")
    public int getProcessParametersIsOk() {
        return ProcessParametersIsOk;
    }

    public void setProcessParametersIsOk(int processParametersIsOk) {
        ProcessParametersIsOk = processParametersIsOk;
    }

    @JsonProperty("EnvironmentalParametersIsOk")
    public int getEnvironmentalParametersIsOk() {
        return EnvironmentalParametersIsOk;
    }

    public void setEnvironmentalParametersIsOk(int environmentalParametersIsOk) {
        EnvironmentalParametersIsOk = environmentalParametersIsOk;
    }

    @JsonProperty("QualityParametersIsOk")
    public int getQualityParametersIsOk() {
        return QualityParametersIsOk;
    }

    public void setQualityParametersIsOk(int qualityParametersIsOk) {
        QualityParametersIsOk = qualityParametersIsOk;
    }

    @JsonProperty("MaterialIsWrite")
    public int getMaterialIsWrite() {
        return MaterialIsWrite;
    }

    public void setMaterialIsWrite(int materialIsWrite) {
        MaterialIsWrite = materialIsWrite;
    }

    @JsonProperty("ProcessParametersIsWrite")
    public int getProcessParametersIsWrite() {
        return ProcessParametersIsWrite;
    }

    public void setProcessParametersIsWrite(int processParametersIsWrite) {
        ProcessParametersIsWrite = processParametersIsWrite;
    }

    @JsonProperty("EnvironmentalParametersIsWrite")
    public int getEnvironmentalParametersIsWrite() {
        return EnvironmentalParametersIsWrite;
    }

    public void setEnvironmentalParametersIsWrite(int environmentalParametersIsWrite) {
        EnvironmentalParametersIsWrite = environmentalParametersIsWrite;
    }

    @JsonProperty("StationID")
    public int getStationID() {
        return StationID;
    }

    public void setStationID(int stationID) {
        StationID = stationID;
    }

    @JsonProperty("StationStatus")
    public int getStationStatus() {
        return StationStatus;
    }

    public void setStationStatus(int stationStatus) {
        StationStatus = stationStatus;
    }

    @JsonProperty("IsSpotCheck")
    public int getIsSpotCheck() {
        return IsSpotCheck;
    }

    public void setIsSpotCheck(int isSpotCheck) {
        IsSpotCheck = isSpotCheck;
    }

    @JsonProperty("StationName")
    public String getStationName() {
        return StationName;
    }

    public void setStationName(String stationName) {
        StationName = stationName;
    }

    @JsonProperty("StationCode")
    public String getStationCode() {
        return StationCode;
    }

    public void setStationCode(String stationCode) {
        StationCode = stationCode;
    }
}
